package org.jeecg.modules.sggg.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecg.common.aspect.annotation.Dict;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * @Description: 商品信息表
 * @Author: jeecg-boot
 * @Date: 2023-03-30
 * @Version: V1.0
 */
@Data
@TableName ("sg_goods")
@Accessors (chain = true)
@EqualsAndHashCode (callSuper = false)
@ApiModel (value = "sg_goods对象", description = "商品信息表")
public class SgGoods implements Serializable {
    private static final long serialVersionUID = 1L;

    /**
     * 主键
     */
    @TableId (type = IdType.ASSIGN_ID)
    @ApiModelProperty (value = "主键")
    private String id;
    /**
     * 创建人
     */
    @ApiModelProperty (value = "创建人")
    private String createBy;
    /**
     * 创建日期
     */
    @JsonFormat (timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat (pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty (value = "创建日期")
    private Date createTime;
    /**
     * 更新人
     */
    @ApiModelProperty (value = "更新人")
    private String updateBy;
    /**
     * 更新日期
     */
    @JsonFormat (timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat (pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty (value = "更新日期")
    private Date updateTime;
    /**
     * 所属部门
     */
    @ApiModelProperty (value = "所属部门")
    private String sysOrgCode;
    /**
     * 商品名称
     */
    @Excel (name = "商品名称", width = 15)
    @ApiModelProperty (value = "商品名称")
    private String name;
    /**
     * 商品类型id
     */
    @Excel (name = "商品类型id", width = 15)
    @Dict (dictTable = "sg_category", dicText = "name", dicCode = "id")
    @ApiModelProperty (value = "商品类型id")
    private String categoryId;
    /**
     * 商品编码
     */
    @Excel (name = "商品编码", width = 15)
    @ApiModelProperty (value = "商品编码")
    private String goodsSn;
    /**
     * 商品库存
     */
    @Excel (name = "商品库存", width = 15)
    @ApiModelProperty (value = "商品库存")
    private Integer goodsNumber;
    /**
     * 是否上架
     */
    @Excel (name = "是否上架", width = 15, dicCode = "is_on_sale")
    @Dict (dicCode = "is_on_sale")
    @ApiModelProperty (value = "是否上架")
    private Integer isOnSale;
    /**
     * 列表图
     */
    @Excel (name = "列表图", width = 15)
    @ApiModelProperty (value = "列表图")
    private String listPicUrl;
    /**
     * 健康币
     */
    @Excel (name = "健康币", width = 15)
    @ApiModelProperty (value = "健康币")
    private Integer currency;
    /**
     * 市场价
     */
    @Excel (name = "市场价", width = 15)
    @ApiModelProperty (value = "市场价")
    private Integer marketPrice;
    /**
     * 是否限购
     */
    @Excel (name = "是否限购", width = 15, dicCode = "isLimited")
    @Dict (dicCode = "isLimited")
    @ApiModelProperty (value = "是否限购")
    private Integer isLimited;
    /**
     * 限购数量
     */
    @Excel (name = "限购数量", width = 15)
    @ApiModelProperty (value = "限购数量")
    private Integer limitedCount;
    /**
     * 主页图
     */
    @Excel (name = "主页图", width = 15)
    @ApiModelProperty (value = "主页图")
    private String images;
    /**
     * 视频链接
     */
    @Excel (name = "视频链接", width = 15)
    @ApiModelProperty (value = "视频链接")
    private String videoUrl;
    /**
     * 商品详情
     */
    @Excel (name = "商品详情", width = 15)
    @ApiModelProperty (value = "商品详情")
    private String goodsDetail;
    /**
     * 销量
     */
    @Excel (name = "销量", width = 15)
    @ApiModelProperty (value = "销量")
    private Integer sales;
    /**
     * 浏览量
     */
    @Excel (name = "浏览量", width = 15)
    @ApiModelProperty (value = "浏览量")
    private Integer views;
    /**
     * 是否删除
     */
    @ApiModelProperty (value = "是否删除")
    private Integer isDelete;

    /**
     * 商品有效天数
     */
    @ApiModelProperty (value = "商品有效天数")
    private Integer effectiveDays;
}
